.class public Lrexsee/opengl/GLRender;
.super Ljava/lang/Object;
.source "GLRender.java"

# interfaces
.implements Landroid/opengl/GLSurfaceView$Renderer;


# instance fields
.field private final colorBuffer:Ljava/nio/IntBuffer;

.field one:I

.field private final quateBuffer:Ljava/nio/IntBuffer;

.field rotateQuad:F

.field rotateTri:F

.field private final triggerBuffer:Ljava/nio/IntBuffer;


# direct methods
.method public constructor <init>()V
    .locals 8

    .prologue
    const/4 v7, 0x4

    const/4 v6, 0x1

    const/4 v5, 0x0

    const/4 v4, 0x7

    const/4 v3, 0x3

    .line 10
    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    .line 13
    const/high16 v0, 0x10000

    iput v0, p0, Lrexsee/opengl/GLRender;->one:I

    .line 16
    const/16 v0, 0x9

    new-array v0, v0, [I

    .line 17
    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    aput v1, v0, v6

    .line 18
    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    neg-int v1, v1

    aput v1, v0, v3

    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    neg-int v1, v1

    aput v1, v0, v7

    const/4 v1, 0x6

    .line 19
    iget v2, p0, Lrexsee/opengl/GLRender;->one:I

    aput v2, v0, v1

    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    neg-int v1, v1

    aput v1, v0, v4

    invoke-static {v0}, Ljava/nio/IntBuffer;->wrap([I)Ljava/nio/IntBuffer;

    move-result-object v0

    iput-object v0, p0, Lrexsee/opengl/GLRender;->triggerBuffer:Ljava/nio/IntBuffer;

    .line 23
    const/16 v0, 0xc

    new-array v0, v0, [I

    .line 24
    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    aput v1, v0, v5

    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    aput v1, v0, v6

    .line 25
    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    neg-int v1, v1

    aput v1, v0, v3

    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    neg-int v1, v1

    aput v1, v0, v7

    const/4 v1, 0x6

    .line 26
    iget v2, p0, Lrexsee/opengl/GLRender;->one:I

    aput v2, v0, v1

    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    neg-int v1, v1

    aput v1, v0, v4

    const/16 v1, 0x9

    .line 27
    iget v2, p0, Lrexsee/opengl/GLRender;->one:I

    neg-int v2, v2

    aput v2, v0, v1

    const/16 v1, 0xa

    iget v2, p0, Lrexsee/opengl/GLRender;->one:I

    neg-int v2, v2

    aput v2, v0, v1

    invoke-static {v0}, Ljava/nio/IntBuffer;->wrap([I)Ljava/nio/IntBuffer;

    move-result-object v0

    iput-object v0, p0, Lrexsee/opengl/GLRender;->quateBuffer:Ljava/nio/IntBuffer;

    .line 30
    const/16 v0, 0xc

    new-array v0, v0, [I

    .line 31
    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    aput v1, v0, v5

    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    aput v1, v0, v3

    const/4 v1, 0x5

    .line 32
    iget v2, p0, Lrexsee/opengl/GLRender;->one:I

    aput v2, v0, v1

    iget v1, p0, Lrexsee/opengl/GLRender;->one:I

    aput v1, v0, v4

    const/16 v1, 0xa

    .line 33
    iget v2, p0, Lrexsee/opengl/GLRender;->one:I

    aput v2, v0, v1

    const/16 v1, 0xb

    iget v2, p0, Lrexsee/opengl/GLRender;->one:I

    aput v2, v0, v1

    invoke-static {v0}, Ljava/nio/IntBuffer;->wrap([I)Ljava/nio/IntBuffer;

    move-result-object v0

    iput-object v0, p0, Lrexsee/opengl/GLRender;->colorBuffer:Ljava/nio/IntBuffer;

    .line 10
    return-void
.end method


# virtual methods
.method public onDrawFrame(Ljavax/microedition/khronos/opengles/GL10;)V
    .locals 8
    .param p1, "gl"    # Ljavax/microedition/khronos/opengles/GL10;

    .prologue
    const/4 v7, 0x3

    const/high16 v6, 0x3f800000    # 1.0f

    const/high16 v5, 0x3f000000    # 0.5f

    const/4 v4, 0x0

    const/4 v3, 0x0

    .line 39
    const/16 v0, 0x4100

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glClear(I)V

    .line 42
    invoke-interface {p1}, Ljavax/microedition/khronos/opengles/GL10;->glLoadIdentity()V

    .line 43
    const/high16 v0, -0x40400000    # -1.5f

    const/high16 v1, -0x3f400000    # -6.0f

    invoke-interface {p1, v0, v3, v1}, Ljavax/microedition/khronos/opengles/GL10;->glTranslatef(FFF)V

    .line 44
    iget v0, p0, Lrexsee/opengl/GLRender;->rotateTri:F

    invoke-interface {p1, v0, v3, v6, v3}, Ljavax/microedition/khronos/opengles/GL10;->glRotatef(FFFF)V

    .line 45
    const v0, 0x8074

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glEnableClientState(I)V

    .line 46
    const v0, 0x8076

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glEnableClientState(I)V

    .line 47
    const/4 v0, 0x4

    const/16 v1, 0x140c

    iget-object v2, p0, Lrexsee/opengl/GLRender;->colorBuffer:Ljava/nio/IntBuffer;

    invoke-interface {p1, v0, v1, v4, v2}, Ljavax/microedition/khronos/opengles/GL10;->glColorPointer(IIILjava/nio/Buffer;)V

    .line 48
    const/16 v0, 0x140c

    iget-object v1, p0, Lrexsee/opengl/GLRender;->triggerBuffer:Ljava/nio/IntBuffer;

    invoke-interface {p1, v7, v0, v4, v1}, Ljavax/microedition/khronos/opengles/GL10;->glVertexPointer(IIILjava/nio/Buffer;)V

    .line 49
    const/4 v0, 0x4

    invoke-interface {p1, v0, v4, v7}, Ljavax/microedition/khronos/opengles/GL10;->glDrawArrays(III)V

    .line 50
    const v0, 0x8076

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glDisableClientState(I)V

    .line 51
    invoke-interface {p1}, Ljavax/microedition/khronos/opengles/GL10;->glFinish()V

    .line 54
    invoke-interface {p1}, Ljavax/microedition/khronos/opengles/GL10;->glLoadIdentity()V

    .line 55
    const/high16 v0, 0x3fc00000    # 1.5f

    const/high16 v1, -0x3f400000    # -6.0f

    invoke-interface {p1, v0, v3, v1}, Ljavax/microedition/khronos/opengles/GL10;->glTranslatef(FFF)V

    .line 56
    invoke-interface {p1, v5, v5, v6, v6}, Ljavax/microedition/khronos/opengles/GL10;->glColor4f(FFFF)V

    .line 57
    iget v0, p0, Lrexsee/opengl/GLRender;->rotateQuad:F

    invoke-interface {p1, v0, v6, v3, v3}, Ljavax/microedition/khronos/opengles/GL10;->glRotatef(FFFF)V

    .line 58
    const/16 v0, 0x140c

    iget-object v1, p0, Lrexsee/opengl/GLRender;->quateBuffer:Ljava/nio/IntBuffer;

    invoke-interface {p1, v7, v0, v4, v1}, Ljavax/microedition/khronos/opengles/GL10;->glVertexPointer(IIILjava/nio/Buffer;)V

    .line 59
    const/4 v0, 0x5

    const/4 v1, 0x4

    invoke-interface {p1, v0, v4, v1}, Ljavax/microedition/khronos/opengles/GL10;->glDrawArrays(III)V

    .line 60
    invoke-interface {p1}, Ljavax/microedition/khronos/opengles/GL10;->glFinish()V

    .line 62
    const v0, 0x8074

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glDisableClientState(I)V

    .line 63
    iget v0, p0, Lrexsee/opengl/GLRender;->rotateTri:F

    add-float/2addr v0, v5

    iput v0, p0, Lrexsee/opengl/GLRender;->rotateTri:F

    .line 64
    iget v0, p0, Lrexsee/opengl/GLRender;->rotateQuad:F

    sub-float/2addr v0, v5

    iput v0, p0, Lrexsee/opengl/GLRender;->rotateQuad:F

    .line 66
    return-void
.end method

.method public onSurfaceChanged(Ljavax/microedition/khronos/opengles/GL10;II)V
    .locals 7
    .param p1, "gl"    # Ljavax/microedition/khronos/opengles/GL10;
    .param p2, "width"    # I
    .param p3, "height"    # I

    .prologue
    const/4 v3, 0x0

    const/high16 v4, 0x3f800000    # 1.0f

    .line 70
    int-to-float v0, p2

    int-to-float v1, p3

    div-float v2, v0, v1

    .line 71
    .local v2, "ratio":F
    invoke-interface {p1, v3, v3, p2, p3}, Ljavax/microedition/khronos/opengles/GL10;->glViewport(IIII)V

    .line 72
    const/16 v0, 0x1701

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glMatrixMode(I)V

    .line 73
    invoke-interface {p1}, Ljavax/microedition/khronos/opengles/GL10;->glLoadIdentity()V

    .line 74
    neg-float v1, v2

    const/high16 v3, -0x40800000    # -1.0f

    const/high16 v6, 0x41200000    # 10.0f

    move-object v0, p1

    move v5, v4

    invoke-interface/range {v0 .. v6}, Ljavax/microedition/khronos/opengles/GL10;->glFrustumf(FFFFFF)V

    .line 75
    const/16 v0, 0x1700

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glMatrixMode(I)V

    .line 76
    invoke-interface {p1}, Ljavax/microedition/khronos/opengles/GL10;->glLoadIdentity()V

    .line 77
    return-void
.end method

.method public onSurfaceCreated(Ljavax/microedition/khronos/opengles/GL10;Ljavax/microedition/khronos/egl/EGLConfig;)V
    .locals 2
    .param p1, "gl"    # Ljavax/microedition/khronos/opengles/GL10;
    .param p2, "config"    # Ljavax/microedition/khronos/egl/EGLConfig;

    .prologue
    const/4 v1, 0x0

    .line 81
    const/16 v0, 0x1d01

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glShadeModel(I)V

    .line 82
    invoke-interface {p1, v1, v1, v1, v1}, Ljavax/microedition/khronos/opengles/GL10;->glClearColor(FFFF)V

    .line 83
    const/high16 v0, 0x3f800000    # 1.0f

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glClearDepthf(F)V

    .line 84
    const/16 v0, 0xb71

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glEnable(I)V

    .line 85
    const/16 v0, 0x203

    invoke-interface {p1, v0}, Ljavax/microedition/khronos/opengles/GL10;->glDepthFunc(I)V

    .line 86
    const/16 v0, 0xc50

    const/16 v1, 0x1101

    invoke-interface {p1, v0, v1}, Ljavax/microedition/khronos/opengles/GL10;->glHint(II)V

    .line 87
    return-void
.end method
